package com.ita.client;

import java.io.BufferedReader;
import java.io.InputStream;
import java.io.InputStreamReader;
import java.io.OutputStream;
import java.net.ServerSocket;
import java.net.Socket;

import com.ita.controller.ServerController;

public class FtpServer {

	public static void main(String[] args) throws Exception{
		ServerSocket server=new ServerSocket(8001);
		while(true){
			Socket socket=server.accept();
			OutputStream out=socket.getOutputStream();
			InputStream in=socket.getInputStream();
			BufferedReader reader=new BufferedReader(new InputStreamReader(in));
			out.write("please input cmd\n".getBytes());
			ServerController controller=new ServerController();
			controller.commandDispatch(in, out);
			
		
		}
		

	}

}
